const express = require('express')

const app = express()

// 定义第一个中间件
app.use(function (req, res, next) {
    console.log('调用第一个全局中间件');

    next()
})

app.use(function (req, res, next) {
    console.log('调用第二个全局中间件');
    next()
})

app.get('/', function (req, res) {
    res.send('Home Page')
})

app.listen(80, () => {
    console.log("server runing at http://127.0.0.1");
})